<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>圆周率弹窗</title>
</head>
<body>
<input type="text" placeholder="半径" id="a">
<input type="text" placeholder="周长" id="b">
<input type="text" placeholder="面积" id="c">

</body>

<script>

    var p = Math.PI;
    var q =prompt("请输入圆的半径");

    document.querySelector("#a").value=q;
    document.querySelector("#b").value=p*(2*q);
    document.querySelector("#c").value=p*(q*q);




</script>

</html>